export default function request(config){
	return new Promise((resolve,reject) =>{
		uni.request({
			url:'http://localhost:9090'+config.url,
			method:config.method||'get',
			data:config.data||{},
			header:{
				Authorization: uni.getStorageSync('token'),
				'Content-Type': 'application/json'
			},
			success(res) {
				resolve(res.data)
			},
			fail(err){
				reject(err)
			}
		})
	})
}